\chapter{User Guide}

\section{Introduction}
Sections in this document: 
\begin{enumerate}
	\item Introduction
	\item Dependencies
	\item Compiling
	\item Running
\end{enumerate}
For general compiling and installing instructions, see the INSTALL file. 


\section{Dependencies}
Particular considerations in this project: \\ \\
The program depends on: \\ \\
\textit{Intel's OpenCV Computer Vision Library, version 2.2.0.} \\ 
You can find it at: http://opencv.sourceforge.net \\ \\ 
\textit{OpenNI unstable version 1.1.0.41.} \\ 
You can find it at: https://github.com/OpenNI/OpenNI/tree/unstable\\ \\
\textit{SensorKinect unstable version 5.0.1.31.} \\
You can find it at: https://github.com/avin2/SensorKinect \\ \\
\textit{NITE version 1.3.1.5} \\
You can find it at: http://www.openni.org/downloadfiles/openni-compliant-middleware-binaries/33-latest-unstable \\ 
 
It depends also on pkg-config, a tool to ease the detection, compilation  and link against libraries. It is used here to compile and link against  OpenCV. If pkg-config is not present, the environment variables OPENCV\_CFLAGS and OPENCV\_LIBS must be defined prior to the call to configure (below). They contain the compiler parameters for compiling and linking. The usual values, when OpenCV is installed in /usr/local, are: 
\begin{code}
OPENCV_CFLAGS = -I/usr/local/include/opencv 
OPENCV_LIBS = -L/usr/local/lib -lcxcore -lcv -lhighgui -lcvaux -lml 
\end{code}


\section{Compiling}
After installing OpenCV, OpenNI, SensorKinect and NITE do: 
\begin{code}
./configure CPPFLAGS=-I/usr/include/ni LIBS=-lOpenNI 
 make 
\end{code}

Optional parameters to configure are: 
\begin{itemize}
  \item 
  \begin{code}
    --disable-debug
  \end{code}      
  \vspace{-1em}
  By default, debug is enabled. This option disables debug mode compilation, debug messages and enables optimizations. 

  \item 
  \begin{code}
    --disable-timer
  \end{code}      
  \vspace{-1em}
  Don't include the time measuring functions. As they are intended to have a benchmarking function, they shouldn't be included in a 'production' version. Also some minor speedup is expected. 

  \item 
  \begin{code}
    --enable-videre-hacks
  \end{code}      
  \vspace{-1em}
  When using the stereohead from Videre Design, some tricks must be enabled in code to support the special characteristics of the device.    
\end{itemize}

\section{Running}
The main executable program is tracker, under src/ directory.

Main keyboard options that is possible enable/disable are: 
\begin{itemize}
	\item z: Depth-zoom mode 
	\item s: Depth-size mode
	\item p: OCR processing 
	\item c: Don't calibrate (if at least one calibration has been done before) enable/disable. 
	\item r: Show the RGB image (with the Arm pointer, hand and skeleton tracking debug information on it).
	\item b: Show the black and white target image. 
	\item i: Retrieving data from the database mode. 
	\item o: Write OCR results on a file. 
	\item t: Use the text tracking techniques to improve the results. 
\end{itemize}

 
 

 



